import http from "@/utils/http";

export const goLoginAPI = (data) => {
  return http({
    url: "/login/wxMin",
    method: "post",
    data,
  });
};
// 模拟登录
export const moniGoLoginAPI = (phoneNumber) => {
  return http({
    url: "/login/wxMin/simple",
    method: "post",
    data: { phoneNumber },
  });
};
// 获取个人信息
export const getUserInfoAPI = () => {
  return http({
    url: "/member/profile",
  });
};
// 改头像
export const postAvatarAPI = (data) => {
  return uni.uploadFile({
    url:'/member/profile/avatar',
    name: 'file',
    filePath: data,
  })
}
// 修改个人信息
export const editInfoAPI = (data) => {
  return http({
    url:'/member/profile',
    method:'put',
    data
  })
}